bimodal blkfront: Create a new node "protocol" in xenstore, add the
authorkfraser@localhost.localdomain <kfraser@localhost.localdomain>
Tue, 23 Jan 2007 14:48:42 +0000 (14:48 +0000)
committerkfraser@localhost.localdomain <kfraser@localhost.localdomain>
Tue, 23 Jan 2007 14:48:42 +0000 (14:48 +0000)
protocol name it speaks there.

Signed-off-by: Gerd Hoffmann <kraxel@suse.de>
linux-2.6-xen-sparse/drivers/xen/blkfront/blkfront.c

index 39b40d835ffa7f7e12ee039d57ecec0a18642929..2a263c0c75c40f7e7ba125feac9157e2a4ad2008 100644 (file)
@@ -44,6 +44,7 @@
 #include <xen/evtchn.h>
 #include <xen/xenbus.h>
 #include <xen/interface/grant_table.h>
+#include <xen/interface/io/protocols.h>
 #include <xen/gnttab.h>
 #include <asm/hypervisor.h>
 #include <asm/maddr.h>
@@ -180,6 +181,12 @@ again:
                message = "writing event-channel";
                goto abort_transaction;
        }
+       err = xenbus_printf(xbt, dev->nodename, "protocol", "%s",
+                           XEN_IO_PROTO_ABI_NATIVE);
+       if (err) {
+               message = "writing protocol";
+               goto abort_transaction;
+       }
 
        err = xenbus_transaction_end(xbt, 0);
        if (err) {